package lib.core.commands
{
	import lib.commands.InitCommand;
	import lib.commands.StartupCompleteCommand;
	import lib.commands.ValidateUrlCommand;
	import lib.config.ApplicationNotifications;
	
	import org.puremvc.as3.patterns.command.MacroCommand;

	public class StartupCommand extends MacroCommand
	{
		override protected function initializeMacroCommand():void
		{
			// Register startup commands
			this.facade.registerCommand(ApplicationNotifications.STARTUP_COMPLETE, StartupCompleteCommand);
						
			// The view prep command registers needed mediators during start-up of the system
			this.addSubCommand(ViewPrepCommand);
			
			// Register URL validate command
			this.facade.registerCommand(ApplicationNotifications.URLRULE_VALIDATE, ValidateUrlCommand);
			
			// This command will be used by the developer to add startup needed 
			this.addSubCommand(InitCommand);
		}
	}
}